package cool.taomu.toolkit.jersey.jetty.entity

import com.fasterxml.jackson.annotation.JsonIgnoreProperties
import org.eclipse.xtend.lib.annotations.Accessors
import org.eclipse.xtend.lib.annotations.ToString

@Accessors
@ToString
@JsonIgnoreProperties(ignoreUnknown=true)
class JettyConfigEntity {
	@Accessors
	@ToString
	@JsonIgnoreProperties(ignoreUnknown=true)
	static class Taomu {
		String title;
		HttpConfig http;
	}

	@Accessors
	@ToString
	@JsonIgnoreProperties(ignoreUnknown=true)
	static class AuthConfig {
		boolean value;
		String admin;
		String email;
	}

	@Accessors
	@ToString
	@JsonIgnoreProperties(ignoreUnknown=true)
	static class HttpConfig {
		String path = "/";
		String name  = "";
		String pathSpec;
		String host  = "0.0.0.0";
		int port = 8080;
		AuthConfig auth;
		String staticPath;
	}
	Taomu taomu;
}
